package io.gitee.zhangbinhub.admin.common.vo

import io.swagger.annotations.ApiModel
import io.swagger.annotations.ApiModelProperty
import org.noear.solon.validation.annotation.NotBlank

/**
 * @since JDK 11
 */
@ApiModel("网关路由配置参数")
data class RouteVo(
    @ApiModelProperty(name = "ID")
    var id: String? = null,

    @ApiModelProperty(name = "路由ID", required = true)
    @field:NotBlank(message = "路由ID不能为空")
    var routeId: String? = null,

    @ApiModelProperty(name = "路由URI", required = true)
    @field:NotBlank(message = "路由URI不能为空")
    var uri: String? = null,

    @ApiModelProperty(name = "路由断言", required = true)
    @field:NotBlank(message = "路由断言不能为空")
    var predicates: String? = null,

    @ApiModelProperty(name = "路由过滤器")
    var filters: String? = null,

    @ApiModelProperty(name = "元数据")
    var metadata: String? = null,

    @ApiModelProperty(name = "路由序号")
    var orderNum: Int = 0,

    @ApiModelProperty(name = "是否启用", required = true)
    var enabled: Boolean? = null,

    @ApiModelProperty(name = "备注")
    var remarks: String? = null
)
